﻿using System;
using Auth.Main;

namespace Auth.MSSQLStore
{
    public partial class UserMap : System.Data.Entity.ModelConfiguration.EntityTypeConfiguration<User>
    {
        public UserMap()
        {
            ToTable("Account_User", "dbo");
            HasKey(t=>t.UserId);
            
            // Properties
            Property(t => t.UserId)
                .HasColumnName("UserId")
                .IsRequired();

            Property(t => t.UserName)
                .HasColumnName("UserName")
                .HasMaxLength(255)
                .IsRequired();

            Property(t => t.Account)
                .HasColumnName("Account")
                .HasMaxLength(255)
                .IsRequired();

            Property(t => t.Password)
               .HasColumnName("Password")
               .HasMaxLength(255)
               .IsRequired();
        }
    }
}
